Skip to content

feat: Add Bitbucket integration#3039

Merged
lucaspin merged 10 commits intosuperplanehq:mainfrom
ishaksebsib:feat/bitbucket
Feb 17, 2026
Merged

feat: Add Bitbucket integration#3039
lucaspin merged 10 commits intosuperplanehq:mainfrom
ishaksebsib:feat/bitbucket

Conversation

@ishaksebsib
Copy link
Contributor

@ishaksebsib ishaksebsib commented Feb 11, 2026

Implements #1956.

This PR adds the Bitbucket integration with an On Push trigger.
It supports workspace authentication via email + API token, lists repositories, and provisions webhooks for push events.
The trigger supports ref filtering via predicates and emits Bitbucket push payloads to workflows.

Demo:

2026-02-11.17-17-28.mp4

@AleksandarCole AleksandarCole added pr:stage-1/3 Needs to pass basic review. wfh pr:stage-2/3 Needs to pass functional review and removed pr:stage-1/3 Needs to pass basic review. labels Feb 11, 2026
@AleksandarCole AleksandarCole assigned lucaspin and unassigned lucaspin Feb 17, 2026
@lucaspin lucaspin marked this pull request as ready for review February 17, 2026 14:34
@lucaspin
Copy link
Contributor

@ishaksebsib I made some changes to support the workspace access tokens. Can you sign-off the commits you have on this branch? Check this document.

@lucaspin lucaspin added pr:stage-3/3 Ready for full, in-depth, review and removed pr:stage-2/3 Needs to pass functional review labels Feb 17, 2026
return fmt.Sprintf("refs/tags/%s", refName)
default:
return fmt.Sprintf("refs/heads/%s", refName)
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extractRef only checks first change, missing subsequent refs

High Severity

extractRef only examines changes[0] in the Bitbucket push payload, but a single push event can contain multiple ref changes (e.g., when multiple branches are updated simultaneously). If a matching ref appears in a later change entry and the first change doesn't match the configured ref filter, the event is silently dropped. The function and caller in HandleWebhook need to iterate over all changes and emit the event if any change matches.

Additional Locations (1)

Fix in Cursor Fix in Web

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

@ishaksebsib ishaksebsib force-pushed the feat/bitbucket branch 2 times, most recently from ec8c23c to 68f347e Compare February 17, 2026 16:18
ishaksebsib and others added 8 commits February 17, 2026 19:23
Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
Signed-off-by: Lucas Pinheiro <lucas@superplane.com>
…tokens

Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
@ishaksebsib
Copy link
Contributor Author

@lucaspin Thanks again for your help! I’ve signed off on the commits and added instructions for adding the tokens.

Signed-off-by: Lucas Pinheiro <lucas@superplane.com>
@lucaspin
Copy link
Contributor

@ishaksebsib thanks. Everything looks good now. Will merge once CI passes

@lucaspin lucaspin merged commit 04483ce into superplanehq:main Feb 17, 2026
4 checks passed
@ishaksebsib
Copy link
Contributor Author

Thanks again @lucaspin, I will send another PR for the other triggers!

hadzija7 pushed a commit to hadzija7/superplane that referenced this pull request Feb 17, 2026
This PR adds the Bitbucket integration, with an initial onPush trigger.

Authentication supports API tokens and workspace access tokens.
Webhooks are provisioned automatically through BitBucket APIs.
The trigger supports ref filtering via predicates and emits Bitbucket
push payloads to workflows.

---------

Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
Signed-off-by: Lucas Pinheiro <lucas@superplane.com>
Co-authored-by: Lucas Pinheiro <lucas@superplane.com>
alabro-bm pushed a commit to alabro-bm/superplane that referenced this pull request Feb 19, 2026
This PR adds the Bitbucket integration, with an initial onPush trigger.

Authentication supports API tokens and workspace access tokens.
Webhooks are provisioned automatically through BitBucket APIs.
The trigger supports ref filtering via predicates and emits Bitbucket
push payloads to workflows.

---------

Signed-off-by: ishaksebsib <ishaksebsib@gmail.com>
Signed-off-by: Lucas Pinheiro <lucas@superplane.com>
Co-authored-by: Lucas Pinheiro <lucas@superplane.com>
Signed-off-by: alabro-bm <atanas.labroski@brightmarbles.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr:stage-3/3 Ready for full, in-depth, review wfh

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments